home *** CD-ROM | disk | FTP | other *** search
/ Joystick Magazine 2000 January / cd joystick no111 janvier 2000.iso / Data / DEMOS.DXR / 00010.ls < prev    next >
Encoding:
Text File  |  1999-12-13  |  1.3 KB  |  62 lines

  1. global gEmptySprite, gEmptySpriteBis
  2.  
  3. on startMovie
  4.   gEmptySpriteBis = 47
  5.   gEmptySprite = 48
  6.   testSprite = 4
  7.   puppetSprite(gEmptySprite, 1)
  8.   puppetSprite(gEmptySpriteBis, 1)
  9.   audioPath = the moviePath & "audio"
  10.   add(the searchPaths, audioPath)
  11. end
  12.  
  13. on idle
  14.   mCast = the mouseCast
  15.   if mCast > 0 then
  16.     checkCursor(mCast)
  17.     CheckHilite(mCast)
  18.   else
  19.     Unhilite()
  20.     cursor(-1)
  21.   end if
  22. end
  23.  
  24. on Unhilite
  25.   set the member of sprite gEmptySprite to member("EMPTY SPRITE")
  26.   set the member of sprite gEmptySpriteBis to member("EMPTY SPRITE")
  27. end
  28.  
  29. on checkCursor mCast
  30.   case word 1 of the name of member mCast of
  31.     "#":
  32.       cursor([4, 5])
  33.     "*":
  34.       cursor([6, 7])
  35.     otherwise:
  36.       cursor(-1)
  37.   end case
  38. end
  39.  
  40. on CheckHilite mCast
  41.   case word 2 of the name of member mCast of
  42.     "$":
  43.       set the member of sprite gEmptySprite to mCast + 1
  44.     "*":
  45.       set the member of sprite gEmptySprite to mCast + 1
  46.       set the member of sprite gEmptySpriteBis to mCast + 2
  47.     "#":
  48.       set the member of sprite gEmptySprite to mCast - 5
  49.     "@":
  50.       nothing()
  51.     otherwise:
  52.       Unhilite()
  53.   end case
  54. end
  55.  
  56. on DoUPDOwn
  57.   set the member of sprite gEmptySprite to member(the memberNum of sprite the clickOn + 1)
  58.   updateStage()
  59.   repeat while the mouseDown
  60.   end repeat
  61. end
  62.